{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "4cc5f6c1",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def AND(x1, x2):\n",
    "    w1, w2, theta = 0.5, 0.5, 0.7\n",
    "    tmp = x1*w1 + x2*w2\n",
    "    if tmp <= theta:\n",
    "         return 0\n",
    "    elif tmp > theta:\n",
    "         return 1\n",
    "\n",
    "AND(0, 0) # 输出0"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "e5fc0aa3",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "AND(1, 0) # 输出0"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "id": "d38d86f2",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "AND(0, 1) # 输出0"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "id": "5913653b",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "AND(1, 1) # 输出1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "7a4ba178",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([0. , 0.5])"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import numpy as np\n",
    "x = np.array([0, 1]) # 输入\n",
    "w = np.array([0.5, 0.5]) # 权重\n",
    "b = -0.7 # 偏置\n",
    "w*x # [0, 1] * [0.5, 0.5] => [0, 0.5]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "c5a50eb2",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0.5"
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "np.sum(w*x)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "1870c2b8",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "-0.19999999999999996"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "np.sum(w*x) + b # -0.19999999999999996 大约为-0.2（由浮点小数造成的运算误差）"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "bb5b6c80",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def AND(x1, x2):\n",
    "    x = np.array([x1, x2])\n",
    "    w = np.array([0.5, 0.5]) # w1和w2是控制输入信号的重要性的参数\n",
    "    b = -0.7 # 偏置是调整神经元被激活的容易程度（输出信号为1的程度）的参数\n",
    "    tmp = np.sum(w*x) + b\n",
    "    if tmp <= 0:\n",
    "        return 0\n",
    "    else:\n",
    "        return 1\n",
    "AND(1,0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "id": "b88e9ed2",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def NAND(x1, x2):\n",
    "    x = np.array([x1, x2])\n",
    "    w = np.array([-0.5, -0.5]) # 仅权重和偏置与AND不同实现非门！\n",
    "    b = 0.7\n",
    "    tmp = np.sum(w*x) + b\n",
    "    if tmp <= 0:\n",
    "        return 0\n",
    "    else:\n",
    "        return 1\n",
    "NAND(1,0)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "fdcb042c",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1"
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def OR(x1, x2):\n",
    "    x = np.array([x1, x2])\n",
    "    w = np.array([0.5, 0.5]) # 仅权重和偏置与AND不同实现或门！\n",
    "    b = -0.2\n",
    "    tmp = np.sum(w*x) + b\n",
    "    if tmp <= 0:\n",
    "        return 0\n",
    "    else:\n",
    "        return 1\n",
    "OR(1,0)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "0f153d40",
   "metadata": {},
   "source": [
    "## 异或门的实现"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "1ed9a634",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "def XOR(x1, x2):\n",
    "    s1 = NAND(x1, x2) # 非门\n",
    "    s2 = OR(x1, x2) # 或门\n",
    "    y = AND(s1, s2) # 将非、或门的结果送入与门\n",
    "    return y # 通过叠加实现非线性\n",
    "XOR(0, 0) # 输出0"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "id": "4f4f4972",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "XOR(1, 0) # 输出1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "id": "caf891b8",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "XOR(0, 1) # 输出1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "id": "cf2f77c8",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "0"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "XOR(1, 1) # 输出0"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "fd6bacb7",
   "metadata": {},
   "source": [
    "# 阶跃函数的图形"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "56b2434e",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAiMAAAGdCAYAAADAAnMpAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/bCgiHAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAiC0lEQVR4nO3df1Bc9b3/8dcCZoka8Jo0m2AIotWWytVcl5qC0hqra9GbqY5T6dgRo9CRaTQSqq0kM2oyzpdpqyk1CjFjYmqNlvFn2/lSDfOd2yQa/X4Nwm2vpj806qKACJ1h0bbg7p7vH8kuWYHIkh/nw/k8HzPMyMk58GbHs7z4nPd5H5/jOI4AAABckuF2AQAAwG6EEQAA4CrCCAAAcBVhBAAAuIowAgAAXEUYAQAAriKMAAAAVxFGAACAq7LcLmAq4vG4enp6NGfOHPl8PrfLAQAAU+A4joaHh5WXl6eMjMnXP2ZEGOnp6VF+fr7bZQAAgGno7u7WokWLJv33GRFG5syZI+nAD5OTk+NyNQAAYCoikYjy8/OTv8cnMyPCSOLSTE5ODmEEAIAZ5vNaLGhgBQAAriKMAAAAVxFGAACAqwgjAADAVYQRAADgKsIIAABwFWEEAAC4ijACAABcRRgBAACuIowAAABXEUYAAICrCCMAAMBVhBEAAOAqwggAAHAVYQQAALiKMAIAAFxFGAEAAK4ijAAAAFcRRgAAgKsIIwAAwFWEEQAA4CrCCAAAcBVhBAAAuCrtMLJr1y4tX75ceXl58vl8ev755z/3mJ07dyoYDCo7O1tnnHGGNm3aNJ1aAQCAB6UdRj755BOdd955evDBB6e0/zvvvKMrrrhC5eXl6uzs1Jo1a7Rq1So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ee6HY5VhkaGtKpp57qdhkz3ujoqDo6OhQKhVK2h0Ih7dmzx6Wq7DA0NCRJ/H98DK1cuVJXXnmlLr30UrdLMdqMeFAeJuY4jlasWKHa2lqVlJTo3Xffdbska7z99tvauHGj7r//frdLmfEGBgYUi8UUCARStgcCAfX19blUlfc5jqP6+npddNFFKi4udrscT/r1r3+t119/Xa+99prbpRiPlRED3XPPPfL5fIf92Lt3rzZu3KhIJKKGhga3S56xpvpaH6qnp0ff+ta39J3vfEc1NTUuVe49Pp8v5XPHccZtw9Fzyy236I9//KOefPJJt0vxpO7ubt122216/PHHlZ2d7XY5xqNnxEADAwMaGBg47D6nn366vvvd7+p3v/tdyht2LBZTZmamvve97+mXv/zlsS51xpvqa514M+np6dGyZcu0dOlSbdu2TRkZ5PkjNTo6qhNPPFFPPfWUrr766uT22267TV1dXdq5c6eL1XnTrbfequeff167du1SYWGh2+V40vPPP6+rr75amZmZyW2xWEw+n08ZGRkaGRlJ+TfbEUZmsHA4rEgkkvy8p6dHl19+uZ5++mktXbpUixYtcrE67/nggw+0bNkyBYNBPf7447yRHEVLly5VMBhUc3NzcttXvvIVffvb36aB9ShyHEe33nqrnnvuOf3hD3/QWWed5XZJnjU8PKz33nsvZduNN96oL3/5y/rxj3/MpbHPoGdkBlu8eHHK5yeffLIk6cwzzySIHGU9PT26+OKLtXjxYt1333366KOPkv+2YMECFyvzhvr6el1//fUqKSlRaWmpNm/erHA4rNraWrdL85SVK1fqiSee0G9+8xvNmTMn2ZOTm5ur2bNnu1ydt8yZM2dc4DjppJM0d+5cgsgECCPAFOzYsUNvvfWW3nrrrXFBj8XFI1dZWanBwUGtX79evb29Ki4uVltbmwoKCtwuzVMSt05ffPHFKdsfffRRrVix4vgXBBzEZRoAAOAquu8AAICrCCMAAMBVhBEAAOAqwggAAHAVYQQAALiKMAIAAFxFGAEAAK4ijAAAAFcRRgAAgKsIIwAAwFWEEQAA4CrCCAAAcNX/B8Cmfri/kqJcAAAAAElFTkSuQmCC",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "import numpy as np\n",
    "import matplotlib.pylab as plt\n",
    "\n",
    "def step_function(x): # 一旦输入超过阈值，就切换输出。这样的函数称为“阶跃函数”。\n",
    "    return np.array(x > 0, dtype=int)\n",
    "\n",
    "x = np.arange(-5.0, 5.0, 0.1)\n",
    "y = step_function(x)\n",
    "plt.plot(x, y)\n",
    "plt.ylim(-0.1, 1.1) # 指定y轴的范围\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "8ff4c36e",
   "metadata": {},
   "source": [
    "# sigmoid函数（sigmoid function）\n",
    "# $$\\sigma(x) = \\frac{1}{1 + e^{-x}}$$"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "5a7118d0",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAiMAAAGdCAYAAADAAnMpAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjcuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/bCgiHAAAACXBIWXMAAA9hAAAPYQGoP6dpAAA5l0lEQVR4nO3deVxVdeL/8fdlu+xXWURQQNxRXKFIy2mnbLX6pk1Ntli/nKnMbJmsabO+w0zbONVoNW1TWdlqy9jCTJNaainivq+ggAjovewX7j2/Pyi+Q6IBAYd77+v5eNwHcTgH3tyH3PvunM/5fCyGYRgCAAAwiZ/ZAQAAgG+jjAAAAFNRRgAAgKkoIwAAwFSUEQAAYCrKCAAAMBVlBAAAmIoyAgAATBVgdoDWcLvdKiwsVEREhCwWi9lxAABAKxiGoYqKCiUkJMjP79jnPzyijBQWFioxMdHsGAAAoB0KCgrUt2/fY37dI8pIRESEpMZfJjIy0uQ0AACgNRwOhxITE5vex4/FI8rIj5dmIiMjKSMAAHiYnxtiwQBWAABgKsoIAAAwFWUEAACYijICAABMRRkB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X4NYZQ3tp9nmpZkcCgA5DGQG6OUdtvab9Y5VKK51KjY/U078eI39W4gXgRSgjQDdW73Lr5gVrtP1gpeIirXr52gyFWwPMjgUAHYoyAnRThmHooY83admOUoUE+uula05QvC3E7FgA0OEoI0A3Ne/rXVrwXb4sFumvV4xWWh+megfgndpVRubNm6eUlBQFBwcrPT1dy5YtO+a+H3zwgc4++2zFxsYqMjJS48aN0xdffNHuwIAvePv7fD3+ReOaMw9eMExZw3ubnAgAOk+by8jChQs1c+ZM3XfffcrLy9OECRM0ceJE5efnt7j/0qVLdfbZZ2vx4sXKzc3V6aefrgsvvFB5eXm/ODzgjXI2H9S9H26QJP3utAG69uQUkxMBQOeyGIZhtOWAzMxMjR07VvPnz2/alpqaqkmTJik7O7tV32P48OGaMmWKHnjggVbt73A4ZLPZZLfbFRkZ2Za4gEdZvbdcV734neoa3Jqc0Vd/vmykLBbunAHgmVr7/t2mMyNOp1O5ubnKyspqtj0rK0vLly9v1fdwu92qqKhQVFTUMfepq6uTw+Fo9gC83faDFbr+1VWqa3DrzKG99MdLRlBEAPiENpWR0tJSuVwuxcXFNdseFxen4uLiVn2PJ598UlVVVZo8efIx98nOzpbNZmt6JCayNDq8257SKl314ndy1DZobFIPPXvlWAX4M74cgG9o16vdT/9vzTCMVv0f3FtvvaWHHnpICxcuVK9evY653+zZs2W325seBQUF7YkJeIT9h6t11d9X6lBFnYb2jtDL156gkCB/s2MBQJdp0+xJMTEx8vf3P+osSElJyVFnS35q4cKFmjZtmt59912dddZZx93XarXKarW2JRrgkQ46anXl379Tob1W/WPD9Pq0TPUIDTI7FgB0qTadGQkKClJ6erpycnKabc/JydH48eOPedxbb72la6+9Vm+++abOP//89iUFvExpZZ2u/PtK5ZdXKykqVG/ecJJiIyjhAHxPm+eVnjVrlq6++mplZGRo3LhxeuGFF5Sfn6/p06dLarzEcuDAAb322muSGovI1KlT9de//lUnnXRS01mVkJAQ2WxM4gTfdLjKqatf+l67DlUpwRasBTdkqrct2OxYAGC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ZeK67Ds911+G57jq+/Fwf74zIjxjACgAATEUZAQAApqKMeCCr1aoHH3xQVqvV7Chej+e66/Bcdx2e667Dc906HjGAFQAAeC/OjAAAAFNRRgAAgKkoIwAAwFSUEQAAYCrKiJeoq6vT6NGjZbFYtHbtWrPjeJ29e/dq2rRpSklJUUhIiAYMGKAHH3xQTqfT7GheY968eUpJSVFwcLDS09O1bNkysyN5nezsbJ1wwgmKiIhQr169NGnSJG3bts3sWD4hOztbFotFM2fONDtKt0QZ8RJ33323EhISzI7htbZu3Sq3263nn39emzZt0l/+8hc999xzuvfee82O5hUWLlyomTNn6r777lNeXp4mTJigiRMnKj8/3+xoXmXJkiW6+eabtXLlSuXk5KihoUFZWVmqqqoyO5pXW7VqlV544QWNHDnS7CjdFrf2eoHPPvtMs2bN0vvvv6/hw4crLy9Po0ePNjuW13v88cc1f/587d692+woHi8zM1Njx47V/Pnzm7alpqZq0qRJys7ONjGZdzt06JB69eqlJUuW6Fe/+pXZcbxSZWWlxo4dq3nz5unRRx/V6NGjNXfuXLNjdTucGfFwBw8e1I033qjXX39doaGhZsfxKXa7XVFRUWbH8HhOp1O5ubnKyspqtj0rK0vLly83KZVvsNvtksS/405088036/zzz9dZZ51ldpRuzSMWykPLDMPQtddeq+nTpysjI0N79+41O5LP2LVrl5555hk9+eSTZkfxeKWlpXK5XIqLi2u2PS4uTsXFxSal8n6GYWjWrFk65ZRTlJaWZnYcr/T2229rzZo1WrVqldlRuj3OjHRDDz30kCwWy3Efq1ev1jPPPCOHw6HZs2ebHdljtfa5/m+FhYU699xzdfnll+uGG24wKbn3sVgszT43DOOobeg4t9xyi9avX6+33nrL7CheqaCgQLfddpveeOMNBQcHmx2n22PMSDdUWlqq0tLS4+7Tr18/XXHFFfrkk0+avWC7XC75+/vrqquu0j/+8Y/OjurxWvtc//hiUlhYqNNPP12ZmZl69dVX5edHn/+lnE6nQkND9e677+qSSy5p2n7bbbdp7dq1WrJkiYnpvNOtt96qRYsWaenSpUpJSTE7jldatGiRLrnkEvn7+zdtc7lcslgs8vPzU11dXbOv+TrKiAfLz8+Xw+Fo+rywsFDnnHOO3nvvPWVmZqpv374mpvM+Bw4c0Omnn6709HS98cYbvJB0oMzMTKWnp2vevHlN24YNG6aLL76YAawdyDAM3Xrrrfrwww/19ddfa9CgQWZH8loVFRXat29fs23XXXedhg4dqt///vdcGvsJxox4sKSkpGafh4eHS5IGDBhAEelghYWFOu2005SUlKQnnnhChw4davpa7969TUzmHWbNmqWrr75aGRkZGjdunF544QXl5+dr+vTpZkfzKjfffLPefPNNffTRR4qIiGgak2Oz2RQSEmJyOu8SERFxVOEICwtTdHQ0RaQFlBGgFb788kvt3LlTO3fuPKrocXLxl5syZYrKyso0Z84cFRUVKS0tTYsXL1ZycrLZ0bzKj7dOn3baac22v/LKK7r22mu7PhDwAy7TAAAAUzH6DgAAmIoyAgAATEUZAQAApqKMAAAAU1FGAACAqSgjAADAVJQRAABgKsoIAAAwFWUEAACYijICAABMRRkBAACmoowAAABT/X+g0EHar+Hv5QAAAABJRU5ErkJggg==",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "def sigmoid(x):\n",
    "    return 1 / (1 + np.exp(-x))\n",
    "\n",
    "x = np.arange(-5.0, 5.0, 0.1)\n",
    "y = sigmoid(x) # 参数x为NumPy数组时，结果也能被正确计算，因为NumPy的广播功能\n",
    "plt.plot(x, y)\n",
    "plt.ylim(-0.1, 1.1) # 指定y轴的范围\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "9bc1b65c",
   "metadata": {},
   "source": [
    "# ReLU（Rectified Linear Unit）函数"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "449735f2",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAiIAAAGiCAYAAADa7K1vAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliI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GRJclauXKl6SherayszOrUqZO1YsUK66qrrrImT55sOpJXuu+++6yBAwcaWz/gz4h888032r9/v4KCgpSZmamWLVtq6NCh2rRpk+loXuvw4cO644479L//+7+KjIw0HcfnlJSUKD4+3nQM4yorK7Vu3ToNGTLkjO1DhgzR6tWrDaXyDSUlJZLEz9F5TJgwQcOGDdO1115rOopXW7p0qXr37q1Ro0apefPmyszM1EsvvdRo6wd8Edm9e7ekmrsKP/jgg3r33XfVtGlTXXXVVTp27JjhdN7HsizddtttGj9+/AXdYTnQ7dq1S88995zGjx9vOopxxcXFcrvdSkpKOmN7UlKSDh06ZCiV97MsS9nZ2Ro4cKDS0tJMx/Faubm5+uabb5STk2M6itfbvXu35s+fr06dOumDDz7Q+PHjNWnSJP3lL39plPX9tojMnDlTDofjJx9ff/21PB6PJOmBBx7QyJEj1atXL73yyityOBxavHix4X+LxlPX4/Xcc8+ptLRU06dPNx3ZqLoer+87cOCAbrjhBo0aNUq//e1vDSX3Pg6H44znlmWdtQ3/vzvvvFMbNmzQwoULTUfxWoWFhZo8ebL++te/Kjw83HQcr+fxeHTppZfq0UcfVWZmpn7/+9/rjjvu0Pz58xtlfVtvemfSnXfeqaysrJ/cp127diorK5MkdevWrXa70+lU+/btA+qCuboer9mzZ2vNmjVn3RSpd+/euvXWW895byF/VNfj9W8HDhzQ4MGD1a9fPy1YsMDmdL4hMTFRwcHBZ539KCoqOussCWpMnDhRS5cu1apVq9S6dWvTcbzWunXrVFRUpF69etVuc7vdWrVqlZ5//nm5XC4FBwcbTOhdWrZsecZ7oCR17dpVb731VqOs77dFJDExUYmJiefdr1evXnI6ndq2bZsGDhwoSaqqqtLevXvVtm1bu2N6jboer3nz5mn27Nm1zw8cOKDrr79eixYtUt++fe2M6FXqerykmrG4wYMH155tCwry2xOR9RIWFqZevXppxYoVuuWWW2q3r1ixQjfffLPBZN7HsixNnDhRS5Ys0aeffqrU1FTTkbzaNddco40bN56x7fbbb1eXLl103333UUJ+YMCAAWeNg2/fvr3R3gP9tojUVWxsrMaPH68ZM2YoJSVFbdu21ZNPPilJGjVqlOF03qdNmzZnPI+OjpYkdejQgf9DO4cDBw5o0KBBatOmjZ566ikdOXKk9u+1aNHCYDLvkJ2drXHjxql37961Z4sKCgq4huYHJkyYoNdff13vvPOOYmJias8ixcXFKSIiwnA67xMTE3PW9TNRUVFKSEjguppzmDp1qvr3769HH31Uo0eP1ldffaUFCxY02tnbgC8ikvTkk08qJCRE48aN0+nTp9W3b199/PHHatq0qelo8HEffvihdu7cqZ07d55V1CxufK0xY8bo6NGjmjVrlg4ePKi0tDQtW7YsoM5G1sW/P6sfNGjQGdtfeeUV3XbbbY0fCH6lT58+WrJkiaZPn65Zs2YpNTVVzz77rG699dZGWd9h8dsQAAAYwofVAADAGIoIAAAwhiICAACMoYgAAABjKCIAAMAYiggAADCGIgIAAIyhiAAAAGMoIgAAwBiKCAAAMIYiAgAAjPl/3+G9suDBxYAAAAAASUVORK5CYII=",
      "text/plain": [
       "<Figure size 640x480 with 1 Axes>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "def relu(x):\n",
    "    return np.maximum(0, x) # x>0 ? y=x : y=0\n",
    "\n",
    "x = np.arange(-6.0, 6.0, 0.1)\n",
    "y = relu(x)\n",
    "plt.plot(x, y)\n",
    "plt.ylim(-1.0, 6.0) # 指定y轴的范围\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "d3b5fff6",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.11.4"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
